package com.yt.biz.impl;

import com.yt.biz.UserService;
import com.yt.dao.UserMapper;
import com.yt.entity.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Classname UserServiceImpl
 * @Description
 * @Date 2021/10/17 19:49
 * @Create by 杨涛
 */
@Service
public class UserServiceImpl implements UserService {
    @Autowired
    UserMapper userMapper;

    public int addUser(String username,String password){
        return userMapper.addUser(username,password);
    }

    public List<User> getUser() {
//        List<User> userlist = null; 老同志新问题啊，总是细节上忘事
        return userMapper.getUser();
    }
}
